from sqlalchemy.orm import Mapped, mapped_column, relationship
from settings.publicvar import Base
from sqlalchemy import String, ForeignKey
from typing_extensions import Annotated

int_pk = Annotated[int,mapped_column(primary_key=True)]
nameset = Annotated[str,mapped_column(String(15),nullable=True)]

class BankCard(Base):
    __tablename__ = 'bankcard'

    id: Mapped[int_pk]
    bankname: Mapped[str]
    name: Mapped[str]
    IDNumber:Mapped[str]
    cardnumber:Mapped[str]
    openbank:Mapped[str]
    IDtype:Mapped[str]
    mark:Mapped[str] = mapped_column(nullable=True)


class BankInfo(Base):
    __tablename__ = 'bankinfo'

    id: Mapped[int_pk]
    bankname: Mapped[str]
    name: Mapped[str]
    IDNumber: Mapped[str]
    cardnumber: Mapped[str]
    openbank: Mapped[str]
    pupose:Mapped[str]

